﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data.SqlClient;

namespace GestionDeCinebox.Classes
{
    public class DataProvider
    {
        public static String conString = "Data Source=DYNG09-PC\\SQLEXPRESS;Initial Catalog=QLRAPPHIM;Integrated Security=True";
        private static SqlConnection con;

        public DataProvider()
        {
            con = new SqlConnection(conString);
        }

        public void Connect()
        {
            con.Open();
        }

        public void CloseConnection()
        {
            con.Close();
        }

        public static SqlConnection Con
        {
            get { return con; }
            set { con = value; }
        }
    }
}
